package com.fzq.design.singleton;

/**
 * @Author 樊志强
 **/
public class SingletonDoubleCheck {

    private SingletonDoubleCheck(){}

    private static volatile SingletonDoubleCheck instance;

    public static SingletonDoubleCheck getInstance(){
        if (instance==null){
            synchronized (SingletonDoubleCheck.class){
                if (instance==null){
                    instance = new SingletonDoubleCheck();
                }
            }
        }
        return instance;
    }

}
